/* jshint esversion: 6 */
import Vue from 'vue';
import Router from 'vue-router';

// import HelloWorld from '@/components/HelloWorld';
//书城
import Home from '@/components/Home/Home';
import TuiJian from '@/components/Home/TuiJian/TuiJian';
import BangDan from '@/components/Home/BangDan/BangDan';
import FenLei from '@/components/Home/FenLei/FenLei';
import XiaoShuo from '@/components/Home/XiaoShuo/XiaoShuo';

//书架
import BookShelf from '@/components/BookShelf/BookShelf';
import MyBooks from '@/components/MyBooks/MyBooks';
import Historys from '@/components/BookShelf/Historys/Historys';
import Download from '@/components/BookShelf/Download/Download';
import Collect from '@/components/BookShelf/Collect/Collect';
Vue.use(Router);

export default new Router({
  routes: [
    {
      path:'/',redirect:'Home'
    },
    {
      path: '/Home',
      name:'home',
      component:Home,
      children:[
        {path:'TuiJian',name:'TuiJian',component: TuiJian},
        {path:'BangDan',name:'BangDan',component: BangDan},
        {path:'FenLei',name:'FenLei',component: FenLei},
        {path:'XiaoShuo',name:'XiaoShuo',component: XiaoShuo},
      ]
    },
    {
      path:'/mybooks',
      name:'MyBooks',
      component:MyBooks
    },
    {
      path:'/BookShelf',
      name:'BookShelf',
      component:BookShelf,
      children:[
        {path:'Collect',name:'Collect',component:Collect},
        {path:'Download',name:'Download',component:Download},
        {path:'Historys',name:'Historys',component: Historys}
      ]
    },   
  ]
});
